Fedora 23
Sponsored Link

FreeIPA Replication
2015/11/05
 
Configure FreeIPA Replication.
[1] Install FreeIPA server's tools on the Replica Host and change DNS settings.
[root@repl01 ~]#
dnf -y install freeipa-server freeipa-server-dns bind bind-dyndb-ldap
[root@repl01 ~]#
nmcli c modify eno16777736 ipv4.dns 10.0.0.30

[root@repl01 ~]#
nmcli c down eno16777736; nmcli c up eno16777736

[2] Add DNS entry for Replica Host on FreeIPA server.
# ipa dnsrecord-add [domain name] [record name] [record type] [record]

[root@dlp ~]#
ipa dnsrecord-add srv.world repl01 --a-rec 10.0.0.51

  Record name: repl01
  A record: 10.0.0.51

[root@dlp ~]#
ipa-replica-prepare repl01.srv.world --ip-address 10.0.0.51

Directory Manager (existing master) password:    
# Directory Manager password


Preparing replica for repl01.srv.world from dlp.srv.world
Creating SSL certificate for the Directory Server
Creating SSL certificate for the dogtag Directory Server
Creating SSL certificate for the Web Server
Exporting RA certificate
Copying additional files
Finalizing configuration
Packaging replica information into /var/lib/ipa/replica-info-repl01.srv.world.gpg
Adding DNS records for repl01.srv.world
The ipa-replica-prepare command was successful

# transfer generated key to Replica Host

[root@dlp ~]#
scp /var/lib/ipa/replica-info-repl01.srv.world.gpg root@repl01.srv.world:/var/lib/ipa/

root@repl01.srv.world's password:
replica-info-repl01.srv.world.gpg 100% 35KB 34.6KB/s 00:00
[3] Setup as a Replica Server on FreeIPA Replica.
The following example set "--no-forwarders" for DNS, but if you set it, specify like "--forwarder=x.x.x.x".
[root@repl01 ~]#
ipa-replica-install --setup-ca --setup-dns --no-forwarders /var/lib/ipa/replica-info-repl01.srv.world.gpg

Directory Manager (existing master) password:    
# Directory Manager password


Run connection check to master
Check connection from replica to remote master 'dlp.srv.world':
   Directory Service: Unsecure port (389): OK
   Directory Service: Secure port (636): OK
   Kerberos KDC: TCP (88): OK
   Kerberos Kpasswd: TCP (464): OK
   HTTP Server: Unsecure port (80): OK
   HTTP Server: Secure port (443): OK
   PKI-CA: Directory Service port (7389): OK

The following list of ports use UDP protocol and would need to be
checked manually:
   Kerberos KDC: UDP (88): SKIPPED
   Kerberos Kpasswd: UDP (464): SKIPPED

Connection from replica to master is OK.
Start listening on required ports for remote master check
Get credentials to log in to remote master
admin@SRV.WORLD password:    
# admin password


Execute check on remote master
.....
.....
Global DNS configuration in LDAP server is empty
You can use 'dnsconfig-mod' command to set global DNS options that
would override settings in local named.conf files

Restarting the web server
[4] Get Kerberos tickets on Replica Host and verify it's possible to get datas on FreeIPA Directory. If possible, it's OK to setup replication settings. For FreeIPA Clients, it's not necessarry to set additinal settings, Clients can continue to authenticate even if a Server is down.
[root@repl01 ~]#
kinit admin

Password for admin@SRV.WORLD:    
# admin password

[root@repl01 ~]#
klist

Ticket cache: KEYRING:persistent:0:0
Default principal: admin@SRV.WORLD

Valid starting       Expires              Service principal
11/05/2015 21:15:56  11/06/2015 21:15:53  krbtgt/SRV.WORLD@SRV.WORLD

[root@repl01 ~]#
ipa user-find

---------------
5 users matched
---------------
  User login: admin
  Last name: Administrator
  Home directory: /home/admin
  Login shell: /bin/bash
  UID: 1529000000
  GID: 1529000000
  Account disabled: False
  Password: True
  Kerberos keys available: True

  User login: debian
  First name: debian
  Last name: debian
  Home directory: /home/debian
  Login shell: /bin/bash
  Email address: debian@srv.world
  UID: 1529000004
  GID: 1529000004
  Account disabled: False
  Password: True
  Kerberos keys available: True
.....
.....
 
Tweet